Fast Algorithms for Computing the Constrained LCS of Run-Length Encoded Strings

نویسندگان

  • Hsing-Yen Ann
  • Chang-Biau Yang
  • Chiou-Ting Tseng
  • Chiou-Yi Hor
چکیده

In the constrained longest common subsequence (CLCS) problem, we are given two sequences X , Y and the constrained sequence P in run-length encoded (RLE) format, where |X| = n, |Y | = m and |P | = r and the numbers of runs in RLE format are N , M and R, respectively. In this paper, we show that after the sequences are encoded, the CLCS problem can be solved in O(NMr+ r × min{q1, q2} + q3) time, where q1 and q2 denote the numbers of elements in the bottom and right boundaries of the partially matched blocks on the first layer, and q3 denotes the number of elements of whole boundaries of all fully matched cuboids in the DP lattice. If the compression ratio is good, our work obviously outperforms the previously known DP algorithm and the Hunt-and-Szymanski-like algorithm.

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Faster STR-IC-LCS Computation via RLE

The constrained LCS problem asks one to find a longest common subsequence of two input strings A and B with some constraints. The STR-IC-LCS problem is a variant of the constrained LCS problem, where the solution must include a given constraint string C as a substring. Given two strings A and B of respective lengths M and N , and a constraint string C of length at most min{M,N}, the best known ...

متن کامل

Longest common subsequence between run-length-encoded strings: a new algorithm with improved parallelism

Data compression can be used to simultaneously reduce memory, communication and computation requirements of string comparison. In this paper we address the problem of computing the length of the longest common subsequence (LCS) between run-length-encoded (RLE) strings. We exploit RLE both to reduce the complexity of LCS computation from O(M × N) to O(mN + Mn − mn), where M and N are the lengths...

متن کامل

New Efficient Algorithms for LCS and Constrained LCS Problem

In this paper, we study the classic and well-studied longest common subsequence (LCS) problem and a recent variant of it namely constrained LCS (CLCS) problem. In CLCS, the computed LCS must also be a supersequence of a third given string. In this paper, we first present an efficient algorithm for the traditional LCS problem that runs in O(R log log n + n) time, where R is the total number of o...

متن کامل

Variants of Constrained Longest Common Subsequence

In this work, we consider a variant of the classical Longest Common Subsequence problem called Doubly-Constrained Longest Common Subsequence (DC-LCS). Given two strings s1 and s2 over an alphabet Σ, a set Cs of strings, and a function Co : Σ → N , the DC-LCS problem consists in finding the longest subsequence s of s1 and s2 such that s is a supersequence of all the strings in Cs and such that t...

متن کامل

New efficient algorithms for the LCS and constrained LCS problems

In this paper, we study the classic and well-studied longest common subsequence (LCS) problem and a recent variant of it, namely the constrained LCS (CLCS) problem. In the CLCS problem, the computed LCS must also be a supersequence of a third given string. In this paper, we first present an efficient algorithm for the traditional LCS problem that runs in O(R log logn+ n) time, where R is the to...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:
  • Theor. Comput. Sci.

دوره 432  شماره 

صفحات  -

تاریخ انتشار 2009